<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8" session="true"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>
<script type="text/javascript">
		function update(){
			$("#form").attr("action","/tracker/trackerUpdateOk.do");
			$("#form").submit();  
		}  
		  
		function goList(){
			$("#form").attr("action","/tracker/trackerList.do");
			$("#form").submit();    
		}  
</script>  
	
	<h2 class="sub-header">${title}</h2> 	
		<form class="form-horizontal" role="form" name="form" id="form" method="post">
		<input name="trackerNo" id="trackerNo" type="hidden" value="${trackerDetail.trackerNo}">
		  <div class="form-group"> 
		    <label for="inputEmail3" class="col-sm-2 control-label">트래커 상위코드</label>  
		    <div class="col-sm-10">
		      	<select class="form-control" name="trackerGrpNo" id="trackerGrpNo">
					<option value="">상위트래커</option>
					<c:forEach items="${selectorList}" var="selectorList" varStatus="status">
						<option value="${ selectorList.selectorNo }" <c:if test="${ trackerDetail.trackerGrpNo eq selectorList.selectorNo }">selected="selected"</c:if>>${ selectorList.selectorNm }</option>
					</c:forEach>
				</select>    
		    </div>    
		  </div>
		  <div class="form-group">
		    <label for="inputPassword3" class="col-sm-2 control-label">트래커 코드</label>
		    <div class="col-sm-10">
		      <input type="text" class="form-control" name="trackerCd"  id="trackerCd" placeholder="트래커 코드" value="${trackerDetail.trackerCd }">
		    </div>  
		  </div>
		  <div class="form-group">
		    <label for="inputPassword3" class="col-sm-2 control-label">트래커</label>
		    <div class="col-sm-10">
		      <input type="text" class="form-control" name="title"  id="title" placeholder="트래커" value="${trackerDetail.title }">
		    </div>
		  </div>	  	
		  <div class="form-group">
		    <label for="inputPassword3" class="col-sm-2 control-label">내용</label>
		    <div class="col-sm-10">
		      <input type="text" class="form-control" name="content"  id="content" placeholder="내용" value="${trackerDetail.content }">
		    </div>
		  </div>	  
		  <div class="form-group">
		    <label for="inputPassword3" class="col-sm-2 control-label">담당자</label>
		    <div class="col-sm-10">
		      <input type="text" class="form-control" name="handler"  id="handler" placeholder="담당자" value="${trackerDetail.handler }">
		    </div>
		  </div>	    
		  <div class="form-group">
		    <label for="inputPassword3" class="col-sm-2 control-label">시작일</label>
		    <div class="col-sm-10">
		      <input type="text" class="form-control" name="startDt"  id="startDt" placeholder="시작일" value="${trackerDetail.startDt }">
		    </div>
		  </div>	    
		  <div class="form-group">
		    <label for="inputPassword3" class="col-sm-2 control-label">종료일</label>
		    <div class="col-sm-10">
		      <input type="text" class="form-control" name="endDt"  id="endDt" placeholder="종료일" value="${trackerDetail.endDt }">
		    </div>
		  </div>	    
		  <div class="form-group">
		    <div class="col-sm-offset-2 col-sm-10">    
		     	<a class="btn btn-default" href="#" onClick="update()">등록</a>
		     	<a class="btn btn-default" href="#" onClick="goList()">목록</a>
		    </div>
		  </div>
		</form>